export const getStatusGroupName = Object.assign(
  (value: number | null | undefined) => {
    switch (value) {
      case 1:
        return '主状态' as const
      case 2:
        return '报关' as const
      case 3:
        return '清关' as const
      case 4:
        return '预约' as const
      case 5:
        return '保险' as const
      case 6:
        return '异常' as const
      default:
        return `${value ?? ''}`
    }
  },
  { valueList: [1, 2, 3, 4, 5] },
)

export const getStatusName = Object.assign(
  (value: number | null | undefined) => {
    switch (value) {
      case 11:
        return '待处理' as const
      case 12:
        return '待发货' as const
      case 13:
        return '待离港' as const
      case 14:
        return '运输中' as const
      case 15:
        return '待提取' as const
      case 16:
        return '中转中' as const
      case 17:
        return '派送中' as const
      case 18:
        return '已签收' as const
      case 19:
        return '已取消' as const
      case 21:
        return '待审核' as const
      case 22:
        return '待申报' as const
      case 23:
        return '申报中' as const
      case 24:
        return '查验中' as const
      case 25:
        return '已放行' as const
      case 26:
        return '已退单' as const
      case 27:
        return '已取消' as const
      case 31:
        return '待审核' as const
      case 32:
        return '待申报' as const
      case 33:
        return '申报中' as const
      case 34:
        return '待支付关税' as const
      case 35:
        return '查验中' as const
      case 36:
        return '已放行' as const
      case 37:
        return '已退运' as const
      case 38:
        return '已取消' as const
      case 41:
        return '待处理' as const
      case 42:
        return '待预约' as const
      case 43:
        return '待确认' as const
      case 44:
        return '已确认' as const
      case 45:
        return '已签收' as const
      case 46:
        return '已回传' as const
      case 47:
        return '已拒收' as const
      case 48:
        return '已取消' as const
      case 51:
        return '待确认' as const
      case 52:
        return '待投保' as const
      case 53:
        return '已投保' as const
      case 54:
        return '已拒绝' as const
      case 55:
        return '已取消' as const
      case 61:
        return '待分配' as const
      case 62:
        return '调查中' as const
      case 63:
        return '处理中' as const
      case 64:
        return '已解决' as const
      case 65:
        return '已关闭' as const
      case 66:
        return '已取消' as const
      default:
        return `${value ?? ''}`
    }
  },
  { valueList: [11, 12, 13, 21, 22, 23, 24, 31, 32, 33, 41, 42, 43, 51, 52, 53] },
)
